﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using StructureMap.Configuration.DSL;
using Universum.Model.Services.Blog;
using Universum.Model.Services.Indexing;

namespace Universum.Infrastructure.Configuration
{
	public class BlogRegistry : Registry
	{
		public BlogRegistry()
		{
			ForRequestedType<IBlogService>().TheDefaultIsConcreteType<BlogServiceImpl>();
			ForRequestedType<IBlogArticleService>().TheDefaultIsConcreteType<BlogArticleServiceImpl>();
			ForRequestedType<IBlogArticleIndexingService>().
				TheDefaultIsConcreteType<BlogArticleIndexingServiceImpl>().CacheBy(StructureMap.Attributes.InstanceScope.PerRequest);

		}
	}
}
